Following command line parameters are available:

/sendto .. .. ..       - can be used as one parameter to start the program and add all files/folder specified as next parameters               
/input                 - input file name (supports wildcards * ?). Several file masks can be specified, e.g. /input "c:\input\*.mp3;*.wav;*.flac"
/exclude               - specify files to exclude e.g. /exclude "*.mp3". Several file masks can be specified, e.g. /exclude "*.mp3;*.wav;*.flac"
/recurse               - recurse sub-folders
/output                - output path. You can specify output file prefix, e.g. /output "c:\somepath\prefix*" - in this case output file name will be prefixed with string "prefix".
                       - you can use :REPLACE: tag to replace parts of the input path, e.g.
                       - /input "c:\input\aaa\1 /output ":REPLACE:aaa:ZZZZ:1:2" will produce output folder "c:\input\ZZZZ\2" i.e. all occurences of aaa will be replaced with ZZZZ and all occurences of 1 will be replace with 2. 
/sameassource          - output path the same as source
/dest                  - destination format (one of M4A, ALAC, APE, FLAC, MP3, NeroAAC, OGG, RAW, WAV, WMA, WavPack, MPC, MP2, Speex, OFR, Merge, AC3, Shorten, Copy)
/mergedest             - destination format if Merge was specified as /dest (one of M4A, ALAC, APE, FLAC, MP3, NeroAAC, OGG, RAW, WAV, WMA, WavPack, MPC, MP2, Speex, OFR, AC3, Shorten) 
/mergecreatecue        - create CUE file if Merge was specified as /dest 
/mergeembedcue         - embed CUE file if Merge was specified as /dest 
/createfullpath        - same as check box, false by default
/userg                 - apply Replay Gain 
/rgvalue n             - Replay Gain value (by default it's 89 dB)
/applytoaudio          - RG will be applied to audio 
/dest                  - destination format, one from mp3,wma,ogg,ape,flac,wavpack,wav
/mono                  - output will be converted to mono
/timestart             - offset of the 
/timelength            - 
/dispconfig            - will display configuration window for given destination format
/dispoptions           - will display program options
/dispadd               - will display configuration window for additional output File Name options
/disppproproc          - will display configuration window for preprocessing options
/about                 - will display about window
/showmainwindow        - show main window (won't show by default)
/dontshowaddingfiles   - don't show "Adding Files" window (will show by default)
/dontshowprogress      - don't show progress window (will show by default)
/filenamepattern       - set file name pattern (will be used for all cases, default is %filename%)
/p n                   - specify number of parallel files.
/noclose               - don't close program after process has completed (program will be closed anyway, if /showmainwindow is not specified)
/savesettings          - save settings
/showparams            - shows all possible parameters for given output format (program will exit after this)
                         it will show default value so you can guess the type of parameter (number, float or boolean (true/false))
/of .. .. .. ..        - output format specific parameters (you can get full list with /showparams)
                         !! note - this cannot be the first parameter, as all parameters 
                         !! after it will be treated as output format specific ones
/noshowerr             - don't show error message
/nometa                - don't write Metadata to output file
/preservetime          - Preserve timestamp of files and folders
/samplerate            - set Sample Rate for output file. Valid values are 5500, 6000, 7333, 8000, 11025, 16000, 22050, 32000, 44100, 48000, 64000, 88200, 96000, 176400, 192000.
/bitspersample         - set Bits Per Sample for output file. Valid values are 8 and 16.
/limitchannels         - set the max number of channels for output files.
/moveto                - will be moved to this folder after conversion.
/prescan               - if set, mp3 files will be prescanned on load. It will take a bit more time, but seeking will be more precise. Use this switch if you are using /timestart and/or /timelength.
/wmacodec              - specify WMA encoder (see under WMA Settings/Manual/Copy to clipboard)
/wmaformat             - specify WMA format (see under WMA Settings/Manual/Copy to clipboard)
/wmavbr                - specify WMA vbr (see under WMA Settings/Manual/Copy to clipboard)  
/usemp3gain            - use mp3gain for replaygain processing. Will only work if destination is mp3
/fileexists            - set the "When converting, if the destination file already exists" option. Valid values are 1 (default), 2, 3 or 4 (see under Program Settings/3 for description of the values).
/fileexistsd           - if /fileexists = 4 and if this parameter is present, program will show debug info about source and dest files before processing them.
/audiobook             - create audiobook (need to specify /dest as well) 		
/createcue             - crate CUE file	
/logfile               - specify path and name for the logile. If no path and name specified, log file will be create in the destination folder.
/profile               - specify name of the profile to use. It must be created from the GUI before using it. See below for the usage.
/buffersize            - specify buffer size to pass to other CLI encoders (lame.exe, for example).
/remsilence1           - Remove silence from beginning
/remsilence2           - Remove silence from end
/threshold             - Threshold
/applymaxnoclip        - apply Max Noclip Gain to the resulting files
/stdout                - write output to stdout. Currently WAV as output format is supported.
/splitbs               - perform Split By Silence on added files.

To get all possible output parameters for mp3 setting do the follwing:

1) run xrecode2.exe with parameter /showparams

   xrecode2.exe /dest mp3 /showparams

2) copy all settings to clipboard by pressing "Copy to clipboard" button and pick ones you need

3) run xrecode2.exe with needed parameters. you don't need to specify value for boolean parameter, i.e. just specify it's name


Examples:

- Convert flac files to mp3 using default values

xrecode2.exe /input c:\audio\flac\*.* /output c:\converted\output /dest mp3 

- Convert flac files to mp3. Use preset quality with value 4, which stands for V4 (as 0 is CBR320, 1 is for V1, 2 for V2 and so on)

xrecode2.exe /input c:\audio\flac\*.* /output c:\converted\output /dest mp3 /of /UsePreset /Preset 4

- Convert flac files to mp3. Use VBR method with bitrate min=1, max=14 which stand for min bitrate=32, max bitrate=320

xrecode2.exe /input c:\audio\flac\*.* /output c:\converted\output /dest mp3 /of /vbr /VBRMin 1 /VBRMax 14

- Convert flac files to mp3. Use CBR method with bitrate=128

xrecode2.exe /input c:\audio\flac\*.* /output c:\converted\output /dest mp3 /of /cbr 128

- Convert flac files to mp3. Use CBR method with bitrate=128, apply replaygain

xrecode2.exe /input c:\audio\flac\*.* /output c:\converted\output /dest mp3 /userg /rgvalue 91 /of /cbr 128

- Reconvert mp3 files with Replaygain

xrecode2.exe /input c:\rg\*.mp3 /output c:\converted\output /dest mp3 /userg /rgvalue 89 /of /UsePreset /Preset 3

- Convert flac to ogg. Use VBR with bitrate=128

xrecode2.exe /input C:\cmdline\Bheki-16bit.flac  /output c:\converted /dest ogg /of /VBR 128

- Convert flac to ogg. Use Quality 3

xrecode2.exe /input C:\cmdline\Bheki-16bit.flac  /output c:\converted /dest ogg /of /Quality 3

- Convert wav files to flac. Use preset compression option

xrecode2.exe /input c:\audio\wav\*.wav /output c:\converted\output /dest flac /of UseCompression /Compression 4

- Convert wav files to ape. Use preset compression level 3

xrecode2.exe /input c:\audio\wav\*.* /output c:\converted\output /dest ape /UseCompression /Compression 3

- Convert flac files to mp3. First show config options for mp3, then start to process

xrecode2.exe /input c:\audio\flac\*.* /output c:\converted\output /dest mp3 /dispconfig  

- Show About (program will exit after showing About window)

xrecode2.exe /about

- Convert wav files to mp3 using only piece of track

xrecode2.exe /input "C:\converted\output\16bit.wav" /output c:\converted\output /dest mp3 /timestart 21000 /timelength 10000 /of /vbr /VBRMin 1 /VBRMax 14 

- Convert flac files to m4a using default settings

xrecode2.exe /input "C:\test\Bheki-16bit.flac" /output "c:\tmp\to\[ipod]" /dest m4a 

- Convert flac files to m4a using custom settings. Please note, that you must leave "- {OutputFileName}" at the end of the custom CommandLine parameter.

xrecode2.exe /input "C:\test\Bheki-16bit.flac" /output "c:\tmp\to\[ipod]" /dest m4a /of CommandLine "--tvbr 35 --highest - {OutputFileName}"

- Convert flac files to m4a using custom settings. Please note, that you must leave "- {OutputFileName}" at the end of the custom CommandLine parameter.

xrecode2.exe /input "C:\test\Bheki-16bit.flac" /output "c:\tmp\to\[ipod]" /dest m4a /of CommandLine "--tvbr 100 - {OutputFileName}"

- Convert ac3 files to mp3 using custom settings. Please note, that you must leave "- {OutputFileName}" at the end of the custom CommandLine parameter.

xrecode2.exe /input "c:\audio\*.ac3" /output "c:\audio" /logfile /dest mp3 /of CommandLine "-a -m m --noreplaygain -b 80 --cbr --nores - {OutputFileName}"

- Convert flac files to m4a using output file prefix

xrecode2.exe /input "C:\test\Bheki-16bit.flac" /output "c:\tmp\to\[ipod]*" /dest m4a 

- Convert wav files to NeroAAC. Use quality 0.55 (you need to specify 55 instead of 0.55)

xrecode2.exe /input c:\audio\*.wav /output c:\converted\output /dest NeroAAC /UseQuality /of /Quality 55

- Convert wav files to NeroAAC. Use quality 1 (you need to specify 100 instead of 1)

xrecode2.exe /input c:\audio\*.wav /output c:\converted\output /dest NeroAAC /UseQuality /of /Quality 100

- Convert flv files to 8000 kHz mono wav files

xrecode2.exe /input C:\flv\*.flv /output C:\converted\output /dest wav /samplerate 8000 /mono /bitspersample 8 /of

-  Convert to 64Kbs, mono, 44100 and convert only piece of track

xrecode2.exe /input "C:\backup\soundtest\test\cmdline\000040967.mp3" /output "C:\backup\soundtest\test\cmdline\out\mp3_64_mono" /dest mp3  /timestart 31 /timelength 189131 /noshowerr /dontshowprogress /dontshowaddingfiles /nometa /samplerate 44100 /mono /userg /start /of /UseCbr /CBR 64

-  Convert to 64Kbs, mono and convert only piece of track

xrecode2.exe /input "C:\backup\soundtest\test\cmdline\000001814.mp3" /output "C:\backup\soundtest\test\cmdline\out\mp3_64_mono" /dest mp3  /timestart 526 /timelength 362922 /noshowerr /dontshowprogress /dontshowaddingfiles /nometa /userg /start /of /UseCbr /CBR 64 /mono

- Convert DTS file and limit # of output channels to 6

xrecode2.exe /input c:\dts\sample.dts /output "C:\dts" /dest wav /limitchannels 6 /of 

- Convert DTS files, limit # of output channels to 4 and move to folder "c:\dts\old" when done 

xrecode2.exe/input c:\dts\*.dts /output "C:\dts" /dest wav /limitchannels 4 /moveto "c:\dts\old" /of 

- Convert wav files to wma by specifying codec and format

xrecode2.exe" /input "c:\Sourcewav\*.wav" /output "c:\testconvert\wma" /moveto "c:\testconvert\destwav" /dontshowaddingfiles  /dontshowprogress /dest wma /wmacodec "Windows Media Audio 9.2" /wmaformat "10 kbps, 16 kHz, mono CBR" 

- Convert m4a files to mp3. m4a file will only be converted if they are newer than dest. And show some debug info as well before compressing.

xrecode2.exe /input "d:\input\*.m4a" /output "d:\output\cmd.91" /dest mp3 /fileexists 4 /fileexistsd

- Usage of :REPLACE: tag

xrecode2.exe /input "c:\input\flac\*.flac" /output ":REPLACE:\flac\:\mp3\" /dest mp3

- Specify several input masks

xrecode2.exe /input "c:\input\*.mp3;*.wav;*.flac" "d:\output\cmd.91" /dest mp3

- Create MP3 AudioBook from command line

xrecode2.exe /input "h:\ddf\001 - Der Super-Papagei\*.mp3" /output "h:\ddf\001 - Der Super-Papagei" /dest mp3 /audiobook /createcue /filenamepattern %%folder%%

- Create M4B AudioBook from command line

xrecode2.exe /input "h:\ddf\001 - Der Super-Papagei\*.mp3" /output "h:\ddf\001 - Der Super-Papagei" /dest m4a /audiobook

- Convert file using profile "aaa" and create log file as well

xrecode2.exe /input "D:\backup\soundtest\test\mp3\ab\*.mp3" /profile "aaa" /logfile 

- Convert all files, except mp3, to wma

xrecode2.exe /input "c:\Sourcewav\*.wav" /exclude "*.mp3" /output "c:\testconvert\wma" /dest wma 

- Apply maxnoclip gain

xrecode2.exe /input "D:\flac\*.flac" /output "c:\converted\output" /dest mp3 /applymaxnoclip

- Use same as source, create log and move processed files to Recycle Bin.

xrecode2.exe /input "d:\wav\*.wav" /sameassource /recurse /recycle /logfile "c:\converted\output\log.txt" /dest flac

- Output to stdout.

xrecode2.exe /input "D:\test\flac\va\01.flac" /userg /applytoaudio /stdout >C:\converted\output\1.wav

- Split by silence to WAV

xrecode2.exe /input "D:\backup\soundtest\test\silence\silence*.wav" /output "D:\converted\output" /splitbs /dest wav 


- create .bat file to process all .cue files in the current folder

:::::::::::::::::::::::8<:::::::::::::::::::
@echo off
set xr2="C:\Program Files (x86)\xrecode II\xrecode2.exe"

call :treeprocess
goto :eof

:treeprocess
FOR /r %%G IN ("*.cue") DO cmd /c " %xr2% /input "%%G" /output "c:\converted\output" /dest merge /mergedest flac /mergecreatecue /filenamepattern "%%genre%%\%%artist%%\%%year%%. %%album%%"
for /D %%d in (*.cue) do (
    cd %%d
    if exists "*.cue" call :treeprocess
    cd %%d
    cd ..
)

:eof
:::::::::::::::::::::::8<:::::::::::::::::::